$(function() {
	activeStep(1);
	$('#start').datetimepicker({
		lang:'ch',
		format:'Y-m-d H:i',
		formatDate:'Y-m-d',
		formatTime: 'H:i'//格式化时间
	});
	$('#end').datetimepicker({
		lang:'ch',
		format:'Y-m-d H:i',
		formatDate:'Ymd',
		formatTime: 'H:i'//格式化时间
	});
	
	$('.am-form-group').find('.am-btn').on('click', function() {
		activeStep($(this).data('step'));
	});
});

/**
 * 激活步骤
 * @param step
 * @returns
 */
var activeStep = function(step){
	if(step == 1){
		$('#title').html('新建项目');
		
		$('#project_1').show();
		$('#project_2').hide();
		$('#project_3').hide();
	}else if(step == 2){
		$('#title').html('拆分模块');
		
		$('#project_2').show();
		$('#project_1').hide();
		$('#project_3').hide();
	}else{
		$('#title').html('分配任务');
		
		$('#project_3').show();
		$('#project_1').hide();
		$('#project_2').hide();
	}
};